'''
Created on Oct 14, 2009

@author: mkiyer
'''

from veggie.app.rnaseq.cufflinks import Cufflinks
from optparse import OptionParser
import sys
import os

if __name__ == '__main__':
    optionparser = OptionParser("usage: %prog [options] <aligned_reads.sam>")
    optionparser.add_option("-o", "--output-dir",
                            dest="output_dir",
                            default=os.path.curdir)
    optionparser.add_option("-n", "--name",
                            dest="name",
                            default="CUFF",
                            help="name of experiment")
    optionparser.add_option("--inner-dist-mean",
                            dest="inner_dist_mean",
                            default=200)
    optionparser.add_option("-p", dest="num_threads", type="int",
                            default="2",
                            help="number of processors to run job [default=%default]")
    (options, args) = optionparser.parse_args()

    # options
    cufflinks_app = Cufflinks()
    cufflinks_app.run(args[0], options.inner_dist_mean, 
                      num_threads=options.num_threads, 
                      label=options.name)
